﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DataProcessor.DeeplinkData
{
    public class Video
    {
        public String VideoId { get; set; }
        public String Title { get; set; }
        public String Description { get; set; }
        public int ViewCount { get; set; }
        public int NumComments { get; set; }
        public IEnumerable<Comment> Comments { get; set; }
        public string Category { get; set; }
        public bool Deeplink { get; set; }

        public Video()
        {
            Comments = new List<Comment>();
        }

        public Video(Dictionary<string, string> videoData)
        {
            VideoId = videoData["VideoId"];
            Title = videoData["Title"];
            NumComments = int.Parse(videoData["NumComments"]);
            Category = videoData["Category"];
            Deeplink = Convert.ToBoolean(Convert.ToInt16(videoData["Deeplink"]));
            
            Comments = new List<Comment>();
        }
    }
}
